using System;
using System.Collections.Generic;
using System.Text;
using System.ComponentModel;

namespace SMS.WinForms.Controls
{
    /// <summary>
    /// The <see cref="SMS.WinForms.Controls.WizardPageNavigationSettings"/> class defines the page keys to navigate to when a previous,
    /// cancel, help or custom navigation is requested for a page.
    /// </summary>
    [
        TypeConverter(typeof(ExpandableObjectConverter ))
    ]
    public class WizardPageNavigationSettings
    {
        #region Declarations

        /// <summary>
        /// Stores the page key for the next navigation.
        /// </summary>
        private String _nextPageKey;

        /// <summary>
        /// Stores the page key for the previous navigation.
        /// </summary>
        private String _previousPageKey;

        /// <summary>
        /// Stores the page key for the cancel navigation.
        /// </summary>
        private String _cancelPageKey;

        /// <summary>
        /// Stores the page key for the help navigation.
        /// </summary>
        private String _helpPageKey;

        /// <summary>
        /// Stores the page key for the custom navigation.
        /// </summary>
        private String _customPageKey;

        #endregion

        #region Constructors

        /// <summary>
        /// Initializes a new instance of the <see cref="SMS.WinForms.Controls.WizardPageNavigationSettings"/> class.
        /// </summary>
        public WizardPageNavigationSettings()
            : this(String.Empty,
                String.Empty,
                String.Empty,
                String.Empty,
                String.Empty)
        {
        }

        /// <summary>
        /// Initializes a new instance of the <see cref="SMS.WinForms.Controls.WizardPageNavigationSettings"/> class.
        /// </summary>
        /// <param name="nextPage">The next page.</param>
        public WizardPageNavigationSettings(
            String nextPage)
            : this(nextPage,
                String.Empty,
                String.Empty,
                String.Empty,
                String.Empty)
        {
        }

        /// <summary>
        /// Initializes a new instance of the <see cref="SMS.WinForms.Controls.WizardPageNavigationSettings"/> class.
        /// </summary>
        /// <param name="nextPage">The next page.</param>
        /// <param name="previousPage">The previous page.</param>
        public WizardPageNavigationSettings(
            String nextPage,
            String previousPage)
            : this(nextPage,
                previousPage,
                String.Empty,
                String.Empty,
                String.Empty)
        {
        }

        /// <summary>
        /// Initializes a new instance of the <see cref="SMS.WinForms.Controls.WizardPageNavigationSettings"/> class.
        /// </summary>
        /// <param name="nextPage">The next page.</param>
        /// <param name="previousPage">The previous page.</param>
        /// <param name="cancelPage">The cancel page.</param>
        public WizardPageNavigationSettings(
            String nextPage,
            String previousPage,
            String cancelPage)
            : this(nextPage,
                previousPage,
                cancelPage,
                String.Empty,
                String.Empty)
        {
        }

        /// <summary>
        /// Initializes a new instance of the <see cref="SMS.WinForms.Controls.WizardPageNavigationSettings"/> class.
        /// </summary>
        /// <param name="nextPage">The next page.</param>
        /// <param name="previousPage">The previous page.</param>
        /// <param name="cancelPage">The cancel page.</param>
        /// <param name="helpPage">The help page.</param>
        public WizardPageNavigationSettings(
            String nextPage,
            String previousPage,
            String cancelPage,
            String helpPage)
            : this(nextPage,
                previousPage,
                cancelPage,
                helpPage,
                String.Empty)
        {
        }

        /// <summary>
        /// Initializes a new instance of the <see cref="SMS.WinForms.Controls.WizardPageNavigationSettings"/> class.
        /// </summary>
        /// <param name="nextPage">The next page.</param>
        /// <param name="previousPage">The previous page.</param>
        /// <param name="cancelPage">The cancel page.</param>
        /// <param name="helpPage">The help page.</param>
        /// <param name="customPage">The custom page.</param>
        public WizardPageNavigationSettings(
            String nextPage,
            String previousPage,
            String cancelPage,
            String helpPage,
            String customPage)
        {
            _nextPageKey = nextPage;
            _previousPageKey = previousPage;
            _cancelPageKey = cancelPage;
            _helpPageKey = helpPage;
            _customPageKey = customPage;
        }

        #endregion

        #region Methods

        /// <summary>
        /// Returns a <see cref="T:System.String"></see> that represents the current <see cref="T:System.Object"></see>.
        /// </summary>
        /// <returns>
        /// A <see cref="T:System.String"></see> that represents the current <see cref="T:System.Object"></see>.
        /// </returns>
        public override string ToString()
        {
            return String.Empty;
        }

        #endregion

        #region Properties

        /// <summary>
        /// Gets or sets the next page key.
        /// </summary>
        /// <value>The next page key.</value>
        [
            Category("Navigation"),
            Description("The navigation key used to identify the page to navigate to when a Next action is requested."),
            DefaultValue("")
        ]
        public String NextPageKey
        {
            get { return _nextPageKey; }
            set { _nextPageKey = value; }
        }

        /// <summary>
        /// Gets or sets the previous page key.
        /// </summary>
        /// <value>The previous page key.</value>
        [
            Category("Navigation"),
            Description("The navigation key used to identify the page to navigate to when a Previous action is requested."),
            DefaultValue("")
        ]
        public String PreviousPageKey
        {
            get { return _previousPageKey; }
            set { _previousPageKey = value; }
        }

        /// <summary>
        /// Gets or sets the cancel page key.
        /// </summary>
        /// <value>The cancel page key.</value>
        [
            Category("Navigation"),
            Description("The navigation key used to identify the page to navigate to when a Cancel action is requested."),
            DefaultValue("")
        ]
        public String CancelPageKey
        {
            get { return _cancelPageKey; }
            set { _cancelPageKey = value; }
        }

        /// <summary>
        /// Gets or sets the help page key.
        /// </summary>
        /// <value>The help page key.</value>
        [
            Category("Navigation"),
            Description("The navigation key used to identify the page to navigate to when a Help action is requested."),
            DefaultValue("")
        ]
        public String HelpPageKey
        {
            get { return _helpPageKey; }
            set { _helpPageKey = value; }
        }

        /// <summary>
        /// Gets or sets the custom page key.
        /// </summary>
        /// <value>The custom page key.</value>
        [
            Category("Navigation"),
            Description("The navigation key used to identify the page to navigate to when a Custom action is requested."),
            DefaultValue("")
        ]
        public String CustomPageKey
        {
            get { return _customPageKey; }
            set { _customPageKey = value; }
        }
        #endregion
    }
}
